<template>
	<view class="page" :style="themeColor">
		<view
			class="flex flex-direction flex-wrap align-stretch justify-center benben-position-layout flex logOutReason_flex_0"
			:style="{height:(88+StatusBarRpx)+'rpx',paddingTop:StatusBarRpx+'rpx'}">
			<view class='flex flex-wrap align-stretch justify-between logOutReason_fd0_0'>
				<view class='flex flex-wrap align-center logOutReason_fd0_0_c0' @tap.stop="handleJumpDiy"
					data-type="back" data-url="1">
					<text class='fu-iconfont2  logOutReason_fd0_0_c0_c0'>&#xe794;</text>
				</view>
				<view class='flex flex-wrap align-center'>
					<text class='logOutReason_fd0_0_c1_c0'>注销账号</text>
				</view>
				<view class='flex align-center justify-end logOutReason_fd0_0_c2'>
				</view>
			</view>

		</view>
		<view :style="{height: (88+StatusBarRpx)+'rpx'}"></view>
		<view class="loading_css" v-if="!isShow">
			<u-loading size="36" color="#4177DD"></u-loading>
			<view class="loading_text">加载中</view>
		</view>
		
		<block v-else>
			<!---注销账号原因-带图flex布局开始-->
			<view class="flex flex-direction flex-wrap align-stretch logOutReason_flex_1">
				<view class='flex flex-wrap align-center logOutReason_fd1_0'>
					<text class='logOutReason_fd1_0_c0'>账号注销</text>
				</view>
				<text class='logOutReason_fd1_1'>永久注销且无法恢复，请谨慎操作</text>
				<view class='flex flex-wrap align-center logOutReason_fd1_2'>
					<text class='logOutReason_fd1_2_c0'>请选择注销账号的原因：</text>
				</view>
				<view class='flex flex-direction flex-wrap align-stretch'>
					<benben-select-diy ref="showSelectPopup1661340912869"
						class-name='flex flex-direction align-stretch flex' :items.sync="changeType" v-model="changeId"
						default-type="aid" default-label="title" :allow-cancel='false' type="radio" :disabled='false'>
						<template v-for='(item,key0) in changeType'>
							<view v-if="item.isSelected" class='flex align-center flex justify-between logOutReason_fd1_3_c0_c0' :key="key0"
								@tap="$refs.showSelectPopup1661340912869.tapHandle(key0)">
								
								<text class='logOutReason_fd1_3_c0_c0_c1'>{{item.title}}</text>
								<image class='logOutReason_fd1_3_c0_c0_c0' mode="aspectFit" :src='STATIC_URL+"33.png"'>
								</image>
							</view>
							<view v-else class='flex align-center flex justify-between logOutReason_fd1_3_c0_c1' :key="key0"
								@tap="$refs.showSelectPopup1661340912869.tapHandle(key0)">
								
								<text class='logOutReason_fd1_3_c0_c1_c1'>{{item.title}}</text>
								<image class='logOutReason_fd1_3_c0_c1_c0' mode="aspectFit" :src='STATIC_URL+"99.png"'>
								</image>
							</view>
						</template>
					</benben-select-diy>
				</view>
				<text class='logOutReason_fd1_4'>请填写注销原因</text>
				<textarea class='logOutReason_fd1_5' type="text" placeholder="请输入~" confirm-type="done" :maxlength="-1"
					placeholder-style="color:#999;font-size:28rpx" v-model="fd1_5" ></textarea>
			</view>
			<!---注销账号原因-带图flex布局结束-->
			<view class="flex flex-wrap align-center justify-center benben-position-layout flex logOutReason_flex_2">
				<button class='flex-sub logOutReason_fd2_0' @tap.stop="getNext">下一步</button>
			
			</view>
		</block>
		<view :style="{height: '88rpx'}"></view>

	</view>
</template>
<script>
	export default {
		components: {},

		data() {
			return {
				"fd1_5": "",
				"changeType": [],
				"changeId": "1",
				"isShow": false
			};
		},
		computed: {
			themeColor() {
				return this.$store.getters.themeColor
			},

		},
		watch: {},
		onLoad(options) {
			this.get_feedback_type();
		},
		onUnload() {

		},
		onReady() {

		},
		onShow() {

		},
		onHide() {

		},
		onResize() {

		},
		onPullDownRefresh() {

		},
		onReachBottom(e) {

		},
		onPageScroll(e) {

		},
		methods: {
			/**
			 * @description 获取注销原因数据
			 */
			get_feedback_type() {
				this.$api.post(global.apiUrls.post64367e6438da1)
					.then(res => {
						// console.log(res);
						this.isShow = true;
						if (res.data.code == 1) {
							let result = res.data.data;
							this.changeType = result; //获取反馈类型数据
							this.changeId = this.changeType[0].aid;
							this.changeName = this.changeType[0].title;
							// that.active = result.types[0] && result.types[0].id; //默认选中第一个反馈类型
						}
					})
					.catch(err => {
						console.log(err);
					});
			},
			
			getNext() {
				if (!this.fd1_5) {
					this.$message.info('请填写注销原因');
					return;
				}
				uni.redirectTo({
					url: '/pages/xtsz/logOutRisk/logOutRisk?reason=' + this.fd1_5 + '&type_id=' + this.changeId
				})
			}
		}
	};
</script>
<style lang="scss" scoped>
	.page {
		width: 100vw;
		overflow-x: hidden;
		min-height: calc(100vh - var(--window-bottom));
		background: var(--benbenFontColor3);
		background-size: 100% auto !important;
	}

	.logOutReason_flex_0 {
		background: #fff;
		background-size: 100% !important;
		width: 750rpx;
		height: 88rpx;
		overflow: hidden;
		z-index: 10;
		top: 0rpx;
		background-size: 100% auto !important;
	}

	.logOutReason_fd0_0_c2 {
		padding: 0rpx 0rpx 0rpx 0rpx;
		width: 100rpx;
	}

	.logOutReason_fd0_0_c1_c0 {
		font-size: 36rpx;
		font-weight: 500;
		color: #333333;
		line-height: 50rpx;
	}

	.logOutReason_fd0_0_c0_c0 {
		font-size: 36rpx;
		font-weight: 400;
		color: #333;
	}

	.logOutReason_fd0_0_c0 {
		width: 100rpx;
	}

	.logOutReason_fd0_0 {
		padding: 0rpx 32rpx 0rpx 32rpx;
		line-height: 88rpx;
	}

	.logOutReason_flex_1 {
		background: #fff;
		background-size: 100% !important;
		font-size: 32rpx;
		background-size: 100% auto !important;
		padding: 32rpx 32rpx 32rpx 32rpx;
	}

	.logOutReason_fd1_5 {
		background: #F5F5F8;
		background-size: 100% !important;
		border-radius: 16rpx 16rpx 16rpx 16rpx;
		padding: 32rpx 24rpx 032rpx 24rpx;
		height: 186rpx;
		width: 100%;
	}

	.logOutReason_fd1_4 {
		font-size: 24rpx;
		font-weight: 400;
		color: #E90001;
		margin: 48rpx 0rpx 24rpx 0rpx;
		line-height: 48rpx;
	}

	.logOutReason_fd1_3_c0_c1_c1 {
		line-height: 40rpx;
		font-size: 28rpx;
		font-weight: 500;
		color: #333333;
	}

	.logOutReason_fd1_3_c0_c1_c0 {
		width: 36rpx;
		height: 36rpx;
		border-radius: 0rpx 0rpx 0rpx 0rpx;
		margin: 0rpx 20rpx 0rpx 0rpx;
	}

	.logOutReason_fd1_3_c0_c1 {
		border-bottom: 1px solid #eee;
		padding: 32rpx 0rpx 32rpx 0rpx;
	}

	.logOutReason_fd1_3_c0_c0_c1 {
		line-height: 40rpx;
		font-size: 28rpx;
		font-weight: 500;
		color: #333333;
	}

	.logOutReason_fd1_3_c0_c0_c0 {
		width: 36rpx;
		height: 36rpx;
		border-radius: 0rpx 0rpx 0rpx 0rpx;
		margin: 0rpx 20rpx 0rpx 0rpx;
	}

	.logOutReason_fd1_3_c0_c0 {
		border-bottom: 1px solid #eee;
		padding: 32rpx 0rpx 32rpx 0rpx;
	}

	.logOutReason_fd1_2_c0 {
		line-height: 48rpx;
		font-size: 32rpx;
		font-weight: 500;
		color: #333333;
	}

	.logOutReason_fd1_2 {
		padding: 40rpx 0rpx 0rpx 0rpx;
	}

	.logOutReason_fd1_1 {
		line-height: 48rpx;
		font-size: 28rpx;
		font-weight: 400;
		color: #666666;
	}

	.logOutReason_fd1_0_c0 {
		line-height: 48rpx;
		font-size: 32rpx;
		font-weight: 500;
		color: #333333;
	}

	.logOutReason_fd1_0 {
		padding: 32rpx 0rpx 24rpx 0rpx;
	}

	.logOutReason_flex_2 {
		width: 750rpx;
		height: 88rpx;
		overflow: hidden;
		z-index: 10;
		bottom: calc(64rpx + var(--window-bottom));
	}

	.logOutReason_fd2_0 {
		background: rgba(238, 63, 77, 1);
		background-size: 100% !important;
		border-radius: 44rpx 44rpx 44rpx 44rpx;
		font-size: 32rpx;
		color: #fff;
		margin: 0rpx 32rpx 0rpx 32rpx;
		height: 88rpx;
		line-height: 88rpx;
	}
</style>
